<!--
  - Copyright (c) 2021.  北京维数科技有限公司
  - Date :  2021/3/25
  - Author ：F12 Console=> atob("MzMxNDkxODAwQHFxLmNvbQ==")
  - Version ：1.0.0
  -->

<template>
  <div><div class="abstatic-height"></div>
    <div class="app-container calendar-list-container custom-tabs-notop">
        <el-tabs v-model="activeName" @tab-click="handleClick" type="card">
          <!--<el-tab-pane label="传感器" name="first">-->
            <!--<sensorTab :Show.sync="sensorShow"></sensorTab>-->
          <!--</el-tab-pane>-->
          <el-tab-pane label="网关设备" name="second" :lazy='true'>
            <deviceTab :Show.sync="deviceShow"></deviceTab>
          </el-tab-pane>
          <!--<el-tab-pane label="室外传感器" name="third" :lazy='true'>-->
            <!--<outdoorTab :Show.sync="outdoorShow"></outdoorTab>-->
          <!--</el-tab-pane>-->
        </el-tabs>
        
    </div>
  </div>
</template>
<script>
// import sensorTab from "./components/sensorTab";
import deviceTab from "./components/deviceTab";
// import outdoorTab from "./components/outdoorTab";
export default {
  components: { deviceTab },
  data() {
    return {
      activeName:'second',
      // sensorShow:true,
      deviceShow:true,
      // outdoorShow:false
    };
  },
 
  methods: {
    handleClick(val){
      let self = this;
      switch (val.name) {
        case "first":
          self.sensorShow = true;
          self.deviceShow = false;
          self.outdoorShow = false;
              break;
        case "second":
          self.deviceShow = true;
          self.sensorShow = false;
          self.outdoorShow = false;
            break;
        case "third":
          self.outdoorShow = true;
          self.sensorShow = false;
          self.deviceShow = false;
          break;
      }
    },
  },
};
</script>
<style rel="stylesheet/scss" lang="scss">
  .custom-tabs-notop{
    .el-tabs__header{
      margin-bottom: 0;
    }
  }
</style>
